/*    */ package com.qmsk.business.megSend;
/*    */ 
/*    */ import com.utils.http.HttpUtils;
/*    */ import java.io.IOException;
/*    */ import java.util.concurrent.Callable;
/*    */ import org.slf4j.Logger;
/*    */ import org.slf4j.LoggerFactory;
/*    */ 
/*    */ public class SMSRunner
/*    */   implements Callable<Boolean>
/*    */ {
/* 10 */   private static final Logger log = LoggerFactory.getLogger(SMSRunner.class);
/*    */   private final SMSInfo smsInfo;
/*    */ 
/*    */   public SMSRunner(SMSInfo smsInfo)
/*    */   {
/* 14 */     this.smsInfo = smsInfo;
/*    */   }
/*    */ 
/*    */   public Boolean call()
/*    */   {
/*    */     try
/*    */     {
/* 21 */       String sSend = HttpUtils.post(this.smsInfo.toRequstURL(), 
/* 22 */         this.smsInfo.toRequstData());
/* 23 */       SmsState sm = new SmsState();
/* 24 */       ParserSmsStateXml.parserSmsState(sSend, sm);
/* 25 */       int nState = sm.getState();
/* 26 */       if (nState == 0)
/* 27 */         return Boolean.valueOf(true);
/*    */     }
/*    */     catch (IOException e) {
/* 30 */       log.error("IOException :" + e.getMessage());
/*    */     } catch (Exception e) {
/* 32 */       log.error("Exception :" + e.getMessage());
/*    */     }
/* 34 */     return Boolean.valueOf(false);
/*    */   }
/*    */ }

/* Location:           C:\Users\Administrator\Desktop\新建文件夹\WEB-INF\classes\
 * Qualified Name:     com.qmsk.business.megSend.SMSRunner
 * JD-Core Version:    0.5.3
 */